package com.yang.design_principle.liskov_substitution_principle;

import org.omg.CORBA.Request;
import sun.net.www.http.HttpClient;

import javax.xml.ws.Response;

/**
 * @Description: 安全传输数据
 * @Author: 杨 强
 * @CreateTime: 2022-10-12 15:18
 */
public class SecurityTransporter extends Transporter {

    private String appId;
    private String token;

    /**
     * 构造注入
     * @param httpClient
     * @param appId
     * @param token
     */
    public SecurityTransporter(HttpClient httpClient, String appId, String token) {
        super(httpClient);
        this.appId = appId;
        this.token = token;
    }


    @Override
    public Response sendRequest(Request request) {
        // 验证appId  + token
        // 把appId + token 添加到 request中
        return super.sendRequest(request);
    }
}
